#{extends 'main.html' /}
#{set title:'View Plan' /}

<html>
<title > "$(Plan.name)" </title>




	<ul>
		#{list items:items, as:'item'}
		<li>Item: ${item.name}</a></li> #{/list}
	</ul>



<form action="@{Ratings.addRating()}" method = "GET">

Rating: <select name="rating" id="rating">

	<option value = "Low">Low</option>
	<option value = "Medium">Medium</option>
	<option value = "High">High</option>
	 </select>


<a href="@{Plans.viewPlan(plan.id)}"><input type="submit" value="Submit Comment" /></a>

<input type = "hidden" id = "type" name = "type" value ="Plan">
<input type = "hidden" id = "modelID" name = "modelID" value ="${plan.id}">
<input type = "hidden" id = "username" name = "username" value ="${Security.connected()}">

</form>




<form action="@{Comments.addComment()}" >

<label> Comment: </label>

<br />
<textarea rows="2" cols="60" name="content" id="content">
</textarea>
<br />

<a href="@{Plans.viewPlan(plan.id)}"><input type="submit" value="Submit Comment" /></a>

<input type = "hidden" id = "type" name = "type" value ="Plan">
<input type = "hidden" id = "modelID" name = "modelID" value ="${plan.id}">
<input type = "hidden" id = "username" name = "username" value ="${Security.connected()}">


<a href="@{Plans.createCalendar()}?id=0&planId=${planID}" + >view Plan Calendar </a>

</form>

<form action="/plans/viewTimeline">
<input type ="hidden" id = "planID" name ="planID" value ="${plan.id}">
<input type="submit" value="View Timeline" />
</form>

	#{if organizerFlag == true}
	<form action="/plans/viewReqAndStatus">
        <input type ="hidden" id = "planID" name ="planID" value ="${plan.id}">
		<input value="/plans/viewReqAndStatus"><input type="submit" value="Update Requirements & Status" />
	</form>
	#{/if}


</html>
